<!--This is IE DTD patch , Don't delete this line.-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
        "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    <meta http-equiv="Page-Enter" content="blendTrans(Duration=0.3)"/>
    <meta http-equiv="Page-Exit" content="blendTrans(Duration=0.3)"/>
    <title><?php echo $cfg_webname; ?> - 管理中心</title>
    <link href="templates/style/frame.css" rel="stylesheet" type="text/css"/>
    <script type="text/javascript" src="templates/js/jquery.min.js"></script>
    <script type="text/javascript" src="templates/js/frame.js"></script>

</head>
<body>
<audio id="audio" src="../tz.mp3" preload="auto" style="display:none;"></audio>
<div class="header">
    <a href="javascript:;" id="logo" class="logo"></a>
    <div class="user">
        <span class="name">Hi, <?php echo $_SESSION['nickname'];  ?></span>
        <div class="userPanel">
            <a href="javascript:;" class="arrow"></a>
            <div class="panel"
            <?php if(empty($_SESSION['t_adminlevel'])) echo 'style="min-height:158px;"'; ?>>
            <div class="warp">
                <div class="txt">您是尊贵的<?php $r = $dosql->GetOne("SELECT `groupname` FROM `#@__admingroup` WHERE
                    `id`=".$_SESSION['adminlevel']);echo ($levelname = isset($r['groupname']) ? $r['groupname'] :
                    '未启用的组'); ?>
                </div>
                <?php
						if(!empty($_SESSION['t_adminlevel']))
						{
							?>
                <div class="priv"><strong>权限切换</strong><br/>
                    <?php
								$dosql->Execute("SELECT * FROM `#@__admingroup` WHERE `checkinfo`='true' ORDER BY id
                    ASC");
                    while($row = $dosql->GetArray())
                    {
                    echo '<a href="javascript:;" onclick="SelPrivID('.$row['id'].');"
                             title="切换到'.$row['groupname'].'身份">'.ReStrLen($row['groupname'],5).'</a>';
                    }
                    ?>
                </div>
                <?php
						}
						?>
                <div class="info">
                    <div><strong>本次登录</strong><br/><?php echo MyDate('Y-m-d H:i',$_SESSION['logintime']); ?></div>
                    <div>
                        <strong>上次登录</strong><br/><?php echo MyDate('Y-m-d H:i',$_SESSION['lastlogintime']).'&nbsp;&nbsp;'.$_SESSION['lastloginip']; ?>
                    </div>
                </div>
                <div class="actbtn"><a href="admin_update.php?id=<?php $row = $dosql->GetOne(" SELECT `id` FROM
                                       `#@__admin` WHERE username='".$_SESSION[' admin']."'");echo $row['id'];?>"
                    class="edit" target="main">修改密码</a><a href="logout.php" class="logout">退出(ESC)</a></div>
            </div>
        </div>
    </div>

</div>
<ul class="nav">
    <li><a href="home.php" target="main" class="selected"><img src="templates/images/icon16.png" title="工作台">
        <h2>工作台</h2>
    </a></li>
    <li><a href="order.php" target="main"><img src="templates/images/icon06.png" title="工单列表">
        <h2>工单列表</h2>
    </a></li>
    <li><a href="map.php" target="main"><img src="templates/images/l04.png" title="地图模式">
        <h2>地图模式</h2>
    </a></li>
    <li><a href="crm.php" target="main"><img src="templates/images/icon11.png" title="CRM">
        <h2>CRM</h2>
    </a></li>
    <li><a href="fee.php" target="main"><img src="templates/images/icon17.png" title="任务奖励">
        <h2>任务奖励</h2>
    </a></li>
    <li><a href="daping/" target="_black"><img src="templates/images/statistic.png" width="45" title="数据统计">
        <h2>数据统计</h2>
    </a></li>
    <?php if($_SESSION['is_wage']=='1'|| $_SESSION['check_wage']=='1' ){?>
    <li><a href="wage.php" target="main"><img src="templates/images/gongzi.png" width="45" title="工资信息">
        <h2>工资信息</h2>
    </a></li>
    <?php }?>
    <li><a href="zhengshu.php" target="main"><img src="templates/images/sn.png" title="序列号管理">
        <h2>序列号管理</h2>
    </a></li>
    <li><a href="admin_update.php?id=<?php $row = $dosql->GetOne(" SELECT `id` FROM `#@__admin` WHERE
           username='".$_SESSION[' admin']."'");echo $row['id'];?>" class="edit" target="main"><img
            src="templates/images/zbdj.png" title="修改密码">
        <h2>修改密码</h2>
        </a></li>
    <li><a href="javascript:;" target="main" onclick="goout()"><img src="templates/images/wcbb.png" width="45"
                                                                    title="退出系统">
        <h2>退出系统</h2>
    </a></li>
</ul>
</div>
<div class="right2">
    <div class="main">
        <iframe name="main" id="main" frameborder="0" src="map.php"
        <?php if(strpos($_SERVER['HTTP_USER_AGENT'],'MSIE')) echo 'scrolling="yes"'; ?>></iframe>
    </div>
</div>
<div class="lockScreenBg">
    <div class="winBox">
        <div class="pwd">
            解锁密码：
            <div><input type="password" name="password" id="password"/>
                <span onclick="CheckPwd()" class="btn">确 定</span></div>
            <span class="note">&nbsp;</span>
        </div>
    </div>
    <div class="copyright">© 2017 中泓高科</div>
</div>
<script type="text/javascript">
    var audio = $("#audio")[0];
    var time = 0;
    $(document).ready(function () {
        settime();
    });

    function settime() {
        if (time == 10) {
            notice();
            time = 0;
            settime();
        } else {
            setTimeout(function () {
                time++;
                settime();
            }, 1000);
        }
    }

    function notice() {
        $.ajax({
            type: 'post',
            url: "../getOrder.php",
            dataType: 'json',
            data: {},
            success: function (json) {
                //alert(json);
                if (json.success == 1) {
                    notice_window();
                }
                //console.log(json);
            },
            error: function () {
            }
        });
    }

    function notice_window() {
        $('#notice').click();
        audio.play();
        setTimeout(function () {
            $('#notice').click();
        }, 10000);
    }

    $(".nav li a").click(function () {
        $('.nav li a').removeClass("selected");
        $(this).addClass("selected");
    });
</script>
</body>
</html>
